<template>
  <el-container class="common-layout">

    <el-header class="el-header">
      <div style="font-weight: bolder;color:#fff">
        饿了么·运营版
      </div>

      <el-dropdown split-button type="primary">
        欢迎xx
        <template #dropdown>
          <el-dropdown-menu>
            <el-dropdown-item command="changePWD">修改密码</el-dropdown-item>
            <el-dropdown-item command="logout">注销</el-dropdown-item>
          </el-dropdown-menu>
        </template>
      </el-dropdown>
    </el-header>

    <el-container>
      <el-aside width="200px" class="el-aside">
          <el-menu :router=true class="el-menu-vertical-demo">

            <el-menu-item index="/activity">
              <el-icon><Goods/></el-icon>
              <span>活动</span>
            </el-menu-item>

          </el-menu>
      </el-aside>

      <el-main>

        <!--路由嵌套-->
        <router-view/>

      </el-main>
    </el-container>
  </el-container>
</template>

<script>

export default {
  name: "IndexView",
}
</script>

<style scoped>
  .common-layout {
    height: 100%;
    width: 100%;
  }

  .common-layout .el-header{
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color:#0091EA;
  }

  .el-aside {
    background-color: #FFFFFF;
    box-sizing: border-box;
    padding: 20px;
  }

  .el-menu-vertical-demo{
    border: none;
  }
  .el-main {
    background-color: #e9eef3;
  }
</style>